﻿@model Customer
@{
    ViewBag.Title = "Edit";
}


<h4>Cập nhật hồ sơ</h4>
@using (Html.BeginForm("Edit", "Account",
     FormMethod.Post, new { enctype = "multipart/form-data", @class = "form-horizontal", role = "form" }))
{
    @Html.ValidationSummary()

    <div class="row">
        <div class="col-md-4">
            <div class="form-group">
                @Html.LabelFor(m => m.Id, new { @class = "col-md-2 control-label" })
                <div class="col-md-10">
                    @Html.TextBoxFor(m => m.Id, new { @class = "form-control", @readonly = true })
                </div>
            </div>

            @Html.HiddenFor(m => m.Password)

            <div class="form-group">
                @Html.LabelFor(m => m.Fullname, new { @class = "col-md-2 control-label" })
                <div class="col-md-10">
                    @Html.TextBoxFor(m => m.Fullname, new { @class = "form-control" })
                </div>
            </div>

            <div class="form-group">
                @Html.LabelFor(m => m.Email, new { @class = "col-md-2 control-label" })
                <div class="col-md-10">
                    @Html.TextBoxFor(m => m.Email, new { @class = "form-control" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.Photo, new { @class = "col-md-2 control-label" })
                <div class="col-md-10">
                    <input type="file" name="upPhoto" />
                    @Html.HiddenFor(m => m.Photo)
                </div>
            </div>
        </div>
        <div class="col-md-4">
            <div class="form-group">
                <div class="col-md-2"></div>
                <div class="col-md-10">
                    <img style="width:260px;height:300px;" src="~/Images/Customers/@Model.Photo?@Guid.NewGuid()" />
                </div>
            </div>
        </div>
    </div>
    
    
   
   

    @Html.HiddenFor(m => m.Activated)

    <div class="form-group">
        <div class="col-md-offset-2 col-md-10">
            <input type="submit" class="btn btn-default" value="Update" />
        </div>
    </div>
}
@section Scripts {
    @Scripts.Render("~/bundles/jqueryval")
}
